package tasks;
import resources.tasks.LoadingCheckHelper;
import com.rational.test.ft.*;
import com.rational.test.ft.object.interfaces.*;
import com.rational.test.ft.object.interfaces.SAP.*;
import com.rational.test.ft.object.interfaces.WPF.*;
import com.rational.test.ft.object.interfaces.dojo.*;
import com.rational.test.ft.object.interfaces.siebel.*;
import com.rational.test.ft.object.interfaces.flex.*;
import com.rational.test.ft.object.interfaces.generichtmlsubdomain.*;
import com.rational.test.ft.script.*;
import com.rational.test.ft.value.*;
import com.rational.test.ft.vp.*;
import com.ibm.rational.test.ft.object.interfaces.sapwebportal.*;

import core.ControlsMapping;
import core.exceptions.ResultFailureException;
/**
 * Description   : Functional Test Script
 * @author angel.tsvetkov
 */
public class Loading extends LoadingCheckHelper
{
	public static void waitToComplete()
	{
	    boolean visibility = true;
	    int numberOfAtempts = 40;
	    int timeWaitDuration = 2;

		do
		{
			numberOfAtempts--;
			visibility = ControlsMapping.LoadingCheck.wait_image.isExist();
			TimeWait(timeWaitDuration);
		}
		while(visibility == true && numberOfAtempts > 0);
	}
}

